package com.alex.core.enums;

import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * @author cb
 * @date 2019/11/13 13:30
 */
@Getter
@AllArgsConstructor
public enum ApiResponseEnum {
    //
    SUCCESS("200", "响应成功"),
    INTERNAL_SERVER_ERROR("500", "系统出现异常，请联系管理员"),
    PARAM_INVALID("400", "参数无效"),

    CATEGORY_PARENT_ID_INVALID("2000001", "请选择上级分类"),
    CATEGORY_CAN_NOT_FIND_BY_ID("2000002", "查询不到分类"),
    CATEGORY_CAN_NOT_UPDATE_LEVEL_NOT_EQUAL("2000003", "分类不能越级修改，只能修改为原来同等级"),
    CATEGORY_HAS_CHILDREN("2000004", "此分类下有子分类，不允许删除"),
    ;
    private final String code;
    private final String errMsg;
}
